Fixes #38068 - Consistently use errors.add#10399
Fixes #38068 - Consistently use errors.add#10399ekohl wants to merge 1 commit intotheforeman:developfrom
Conversation
Using `errors[:field] << 'the error'` is deprecated in favor of
`errors.add(:field, 'the error')`. Instances found using:
rg 'errors\[.+\]\s+<<'
|
Is this the same as 4d569a2? Also, not all of the |
|
Oh, I think you're right. Shall I close this instead or do we want to get this merged so #10299 is a bit smaller? |
Mostly depends on you :) If you adjust PR, so the tests are green, we can merge it and I'll rebase my PR, no problem. The only thing why I'd like to have these changes in Rails 7 PR, so if anyone will try to see why their plugin stopped working or what we did to upgrade Rails, they'll find this as a must have. But probably this particular change is obvious looking on the Rails change log and deprecation warnings :) |
|
Given how close we are to merging, I'm going to close this. |
Using
errors[:field] << 'the error'is deprecated in favor oferrors.add(:field, 'the error'). Instances found using: